<script type="text/javascript" src="<?php echo baseTheme();?>/js/sammy-0.5.4.min.js"></script>
<?php

?>

<div class="main">
        <div class="inside">
        	<h1>Please chool your model your have</h1>
        	<div style="color:black;margin:10px 0 20px">Showing model for: <?php if($nameCategory!=null) echo $nameCategory;?> </div>		
            <ul class="main_stack series_stack level_1" style="height: auto; padding-left: 30px;" id="dataCat">
				<?php
				if(!empty($subCat)){
					foreach($subCat as $key=>$value){
						$checkSubCat = Gadgetcategory::model()->findAllByAttributes(array(
							'parentCategoryId'=>$value->id
						));
						$isSubCat = false;
						if(!empty($checkSubCat)) $isSubCat = true;
				?>
				<li class="iphone_5 act" data-id="3267" data-name="iphone_5" style="height: auto;">
					<?php
					// dump($keyCategories,false);
					if($isSubCat){
					?>
						<a href="<?php echo Yii::app()->createAbsoluteUrl("category/{$aliasKey}/".strtolower($value->urlKey));?>" style="height: auto; opacity: 1;" class="">
					<?php
					}else{
					?>
						<a href="<?php echo Yii::app()->createAbsoluteUrl("products/".strtolower($value->urlKey));?>" style="height: auto; opacity: 1;" class="">
					<?php
					}
					?>
                  
                    <!-- img src="< ?php echo Yii::app()->baseUrl;?>/uploads/categories/fill/119-145/< ?php echo $value->imageUrl;?>"-->
                    <img src="<?php echo Yii::app()->baseUrl;?>/uploads/categories/<?php echo $value->imageUrl;?>" style='height: 145px'>
                    <h4><?php echo $value->name;?></h4>
                  </a>
                </li>
				<?php
					}
				}
				?>
                

            </ul>
            <br/><br/>
        </div>
        <div style="clear: both"></div>
    </div>